package com.buding.fx.service.impl;

import com.buding.fx.common.enums.ButtonTypeEnum;
import com.buding.fx.utils.ButtonUtils;
import com.jfoenix.controls.JFXButton;
import com.jfoenix.svg.SVGGlyph;
import com.jfoenix.svg.SVGGlyphLoader;
import javafx.geometry.Insets;
import javafx.scene.Node;
import javafx.scene.control.Button;
import javafx.scene.control.Label;
import javafx.scene.layout.*;
import javafx.scene.paint.Color;
import javafx.scene.text.Font;


/**
 * @Author: mingdongwei
 * @Date: 2024-03-31
 * @Description:
 * @Version: 1.0.0
 */
public class TableViewCreateService {

    public static Node create() throws Exception {
        Pane pane = new Pane();
        Border border = new Border(new BorderStroke(Color.web("#E8E2E2"), BorderStrokeStyle.SOLID, new CornerRadii(0), new BorderWidths(1,1,1,1)));
        pane.setBorder(border);

        VBox vBox = new VBox();
        FlowPane flowPane = new FlowPane();
        flowPane.setBorder(border);
        Label label = new Label("表头调整列表");
        label.setStyle("-fx-font-size: 10;");

        Button addButton = ButtonUtils.createButton(50,10,ButtonTypeEnum.ADD,"增加列",30,10);
        Button removeButton = ButtonUtils.createButton(50,10,ButtonTypeEnum.DELETE,"增加列",30,10);

        flowPane.getChildren().addAll(label,addButton,removeButton);

        vBox.getChildren().add(flowPane);
        pane.getChildren().add(vBox);
        return pane;
    }
}
